
import Login from './components/login.vue'
import Home from './components/home.vue'
import Index from './components/index/index.vue'
import UserList from './components/user/list.vue'
import UserInfo from './components/user/info.vue'


import TagCategory from './components/article/tag-category.vue'
import ArticleAdd from './components/article/add.vue'
import ArticleList from './components/article/list.vue'
import ArticleEdit from './components/article/edit.vue'

export default{
  lists(){
    return {
      routes: [
        {path: '/home',
         component: Home,
          children:[
            {path: '/',
              component: Index
            },{
              path: '/user/list',
              component: UserList
            },{
              path: '/user/info',
              component: UserInfo
            },{
              path: '/article/tagcategory',
              component: TagCategory
            },{
              path: '/article/add',
              component: ArticleAdd
            },{
              path: '/article/list',
              component: ArticleList
            },{
              path: '/article/edit/:id',
              name:'edit',
              component: ArticleEdit
            },
          ]
        },{path: '/login',
         component: Login
        },
        { path: '*', redirect: '/home' },
      ]
    }
  }
}